<template lang="jade">
  div#panel-wrap
    div.panel
      div(v-if="!hideTitle")
        div.panel-title(v-if="!pTitle") {{$route.name}}
        div.panel-title(v-else) {{pTitle}}
      div.panel-body
        slot
</template>

<script>
    export default {
        name:'panel',
        props: ['pTitle','hideTitle'],
    }
</script>

<style lang="scss">
  @import '../style/config.scss';

  #panel-wrap{
    padding:$top-bar-height + $base-spacing $base-spacing 44px $sidebar-width + $base-spacing;
  }
  .panel{
    background-color: #fff;
    border: none;
    position: relative;
    -webkit-box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
    box-shadow: 0 1px 1px rgba(0, 0, 0, 0.05);
    .panel-title{
      font-size: $base-font-normal;
      height: 32px;
      line-height: 32px;
      padding: 0 20px;
      border-bottom: 1px solid #ebf1f3;
    }
    .panel-body{
      padding: 20px;
      padding-bottom: 10px;
    }
  }
</style>
